package com.jinglin.entity.po;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.extension.activerecord.Model;

import java.time.LocalDateTime;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableLogic;
import java.io.Serializable;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;

/**
 * <p>
 * 视频播放历史
 * </p>
 *
 * @author ${author}
 * @since 2025-04-03
 */
@Data
@EqualsAndHashCode(callSuper = false)
@ApiModel(value="VideoPlayHistory对象", description="视频播放历史")
public class VideoPlayHistory extends Model<VideoPlayHistory> {

    private static final long serialVersionUID = 1L;

    @TableId(type = IdType.ASSIGN_ID)
    private String videoHistoryId;
    @ApiModelProperty(value = "用户ID")
    private String userId;

    @ApiModelProperty(value = "视频ID")
    private String videoId;

    @ApiModelProperty(value = "文件索引")
    private Integer fileIndex;

    @ApiModelProperty(value = "最后更新时间")
    private LocalDateTime lastUpdateTime;

    @TableField(exist = false)
    private String  videoCover;
    @TableField(exist = false)
    private String videoName;

    @ApiModelProperty(value = "删除为1 未删除为0")
    @TableLogic
    private Integer deleted;


    @Override
    protected Serializable pkVal() {
        return this.userId;
    }

}
